home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 16 / PC Actual CD 16.iso / autocad / R14701.DXR / 00021_s-scrollBarButtonScript.ls < prev    next >
Encoding:
Text File  |  1997-04-24  |  673 b   |  28 lines

  1. on mouseDown
  2.   global gScript
  3.   set tSprite to rollOver()
  4.   if the mouseV > the bottom of sprite the pThumbSprite of gScript then
  5.     set tDirection to "#down"
  6.   else
  7.     if the mouseV < the top of sprite the pThumbSprite of gScript then
  8.       set tDirection to "#up"
  9.     else
  10.       set tDirection to "#none"
  11.     end if
  12.   end if
  13.   set tCurrButton to getaProp(the pButtonObjectList of gScript, tSprite)
  14.   if voidp(tCurrButton) then
  15.     exit
  16.   end if
  17.   mButtonDown(tCurrButton, tDirection)
  18. end
  19.  
  20. on mouseUp
  21.   global gScript
  22.   set tCurrButton to getaProp(the pButtonObjectList of gScript, rollOver())
  23.   if voidp(tCurrButton) then
  24.     exit
  25.   end if
  26.   mButtonUp(tCurrButton)
  27. end
  28.